package com.michael.demos.springboot.ext.service;

import lombok.Data;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.BeansException;
import org.springframework.beans.factory.*;
import org.springframework.stereotype.Service;

/**
 * 类功能描述:
 * <pre>
 *   xxxx
 * </pre>
 *
 * @author Michael
 * @version 1.0
 * @date 2020/9/3 16:19
 */
@Slf4j
@Data
@Service
public class UserService implements InitializingBean, BeanNameAware, BeanClassLoaderAware, BeanFactoryAware {

    private static final long serialVersionUID = 1L;

    private String name;

    @Override
    public void afterPropertiesSet() throws Exception {
        log.error("InitializingBean.afterPropertiesSet()");
    }

    @Override
    public void setBeanName(String name) {
        log.error("BeanNameAware.setBeanName()");
    }

    @Override
    public void setBeanClassLoader(ClassLoader classLoader) {
        log.error("BeanClassLoaderAware.setBeanClassLoader()");
    }

    @Override
    public void setBeanFactory(BeanFactory beanFactory) throws BeansException {
        log.error("BeanFactoryAware.setBeanFactory()");
    }
}
